Skip to content

Fix/retire kitty ctrlv map xwayland#3

Merged
NagyVikt merged 3 commits into
mainfrom
fix/retire-kitty-ctrlv-map-xwayland
Jun 12, 2026
Merged

Fix/retire kitty ctrlv map xwayland#3
NagyVikt merged 3 commits into
mainfrom
fix/retire-kitty-ctrlv-map-xwayland

Conversation

@NagyVikt

Copy link
Copy Markdown
Collaborator

Why

What changed

How tested

Checklist

  • Bash syntax + shellcheck pass through the Lint workflow
  • cargo build --release --locked --manifest-path rs/Cargo.toml passes (if any Rust changed)
  • cargo fmt --manifest-path rs/Cargo.toml --all --check passes (if any Rust changed)
  • cargo clippy --release --locked --manifest-path rs/Cargo.toml -- -D warnings passes (if any Rust changed)
  • flashpaste-doctor runs clean against the changes
  • If this is a vX.Y bump: tag pushed in the same turn (see AGENTS.md)
  • CHANGELOG.md updated under ## [Unreleased]
  • Relevant docs in docs/ updated
  • None of the four hard-won facts (see AGENTS.md) regressed

Type of change

  • Bug fix (no API change)
  • Feature (additive, no breakage)
  • Breaking change (requires a major version bump)
  • Docs only
  • Build / packaging / CI only

NagyVikt added 3 commits June 10, 2026 17:14
…etection

Under XWayland kitty, `kitten @ ls` reports is_focused=false for every OS
window and empty foreground_processes, so kitty-paste-router.sh's
focused_window_is_tmux() can never succeed. Every Ctrl+V took the slow
fallthrough (background launch, seconds late under load) and the late
second fire landed outside the daemon's 2.5s dedup window — journal shows
identical 162-byte text pastes 4s apart (pane %23, 15:14:50 + 15:14:54).

Fix: kitty must not bind ctrl+v at all. tmux's own `bind -n C-v` is the
single handler (~5ms, pane id from the pressing client — also kills the
wrong-pane hazard of the router's target-less `tmux display-message`).
Non-tmux kitty windows: raw 0x16 reaches Claude Code, which reads the
clipboard itself via the wl-paste shim; plain shells use ctrl+shift+v.

- keybindings.canonical: kitty ctrl+v -> UNBOUND (new keyword)
- flashpaste-keybindings-check.sh: support UNBOUND (binding must not exist)
- kitty-paste-router.sh: retired-status header + clip-pipeline-log tracing
  (it was the only paste path with zero logging)
- tests/keybindings-check.test.sh: cover UNBOUND pass/violation + keep
  positive-rule and literal-+ coverage via fixture canonicals
shellcheck -S warning (CI gate) parses $key_re[[:space:]] as an array
expansion and errors. Introduced with the checker in PR #1; this was the
shellcheck regression that turned main's Lint job red. Braces quiet it
with no behavior change (tests 6/6, live check consistent).
@NagyVikt NagyVikt merged commit 9e01a2b into main Jun 12, 2026
5 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant